<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@include file="/WEB-INF/template/common/taglibs.jspf"%>
<es:contentHeader/>

<t:base type="cloudAdmin,fontAwesome,themesDefault,jquery,jquery-ui-bootstrap:jquery-ui,bootstrap-datetimepicker,responsive,bootstrap,blockUI,fullCallender,application,box,layer"></t:base>
<script src="<%=request.getContextPath()%>/resources/plug-in/fullcalendar/fullcalendar.js"></script>
<link rel="stylesheet" href="<%=request.getContextPath()%>/resources/plug-in/fullcalendar/fullcalendar.css?3">
<style>
    .angle:before {
        cursor: pointer;
    }
    .fc-button-add {
        margin-right: 10px!important;
    }

    #loading {
        position: absolute;
        top: 5px;
        right: 5px;
    }

    .ui-dialog {
        overflow: visible!important;
    }
    .ui-dialog-content {
        overflow: visible!important;
    }

    #calendar {
        width: 100%;
        margin: 0 auto;
    }

</style>
<div  class="box border" style="border: 0px">
    <div class="box-title" style="background-color:darkmagenta;height: 42px">
            <i class="fa fa-calendar fa-2x" style="color: white"></i>&nbsp;&nbsp;
            <h4 style="color: white;display: inline">
                我的日历
                (<span class="badge badge-important" data-toggle="tooltip" data-placement="bottom" title="最近，您有${messageUnreadCount}个提醒事项">${messageUnreadCount}个</span>)
                <i class="angle icon-double-angle-down" style="color: white;cursor: pointer"></i>
            </h4>
            <div class="tools">
                <a href="javascript:;" class="reload" title="刷新当前窗口">
                    <i class="fa fa-refresh" style="color: white"></i>
                </a>
            </div>
    </div>
    <div class="box-body" style="display: block;">
        <div id='calendar'></div>
    </div>
</div>
<es:contentFooter/>
<script type="text/javascript">
    $(function() {
        //$.app.initCommonBtn();
        $(".angle").click(function() {
            var next = $(this).parent().parent().next();
            if(next.is(":hidden")) {
                $(this).removeClass("icon-double-angle-up");
                $(this).addClass("icon-double-angle-down");
                next.slideDown(800);
            } else {
                next.slideUp(800);
                $(this).removeClass("icon-double-angle-down");
                $(this).addClass("icon-double-angle-up");
            }
        });
        $.app.initCalendar();

    });
    //页面刷新
    $(".reload").click(function () {
        //加载层-默认风格
        layer.load();
        window.location.reload();
    });
</script>
